<template>
  <div class="bg-white rounded-lg p-5 h-full flex flex-col">
    <div>
      <div class="font-bold text-lg mb-4">添加处置记录</div>
      <el-form
        style="width: 400px"
        ref="form"
        :model="formData"
        label-width="140px"
      >
        <el-form-item label="处置时间">
          <el-input
            v-model="formData.creditCode"
            placeholder="请输入机构代码"
          ></el-input>
        </el-form-item>

        <el-form-item label="处置人员">
          <el-select
            v-model="formData.medicalLevel"
            placeholder="请选择医院级别"
            class="w-full"
          >
            <el-option
              v-for="item in data8Options"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </el-select>
        </el-form-item>

        <el-form-item label="院内医疗废物交接单">
          <el-upload
  action="https://jsonplaceholder.typicode.com/posts/"
  list-type="picture-card"
  :on-preview="handlePictureCardPreview"
  :on-remove="handleRemove">
  <i class="el-icon-plus"></i>
</el-upload>
        </el-form-item>
        <el-form-item label="医疗废物转运联单">
          <el-upload
  action="https://jsonplaceholder.typicode.com/posts/"
  list-type="picture-card"
  :on-preview="handlePictureCardPreview"
  :on-remove="handleRemove">
  <i class="el-icon-plus"></i>
</el-upload>
        </el-form-item>
      </el-form>
    </div>
    <hr class="my-4" />
    <div>
      <el-button @click="goBack">返回</el-button>
      <el-button type="primary" @click="submit" v-if="!$route.query.id"
        >提交</el-button
      >
    </div>
  </div>
</template>

<script>
import {
  getCascaderOptionsFun,
  getSelectOptionsFun,
} from "@/utils/business.js";
export default {
  data() {
    return {
      formData: {
        creditCode: "",
        medicalLevel: "",
        recordStatus: "",
        preventStatus: "",
      },
      fileList: [
        {
          name: "food.jpeg",
          url: "https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100",
        },
        {
          name: "food2.jpeg",
          url: "https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100",
        },
      ],
    };
  },
  mounted() {},
  methods: {
    submit() {
      this.$router.back();
    },
    goBack() {
      this.$router.back();
    },
    handleRemove(file, fileList) {
      console.log(file, fileList);
    },
    handlePreview(file) {
      console.log(file);
    },
  },
};
</script>

<style lang="scss" scoped></style>
